home *** CD-ROM | disk | FTP | other *** search
- Path: mail2news.demon.co.uk!hpl3sn03.cern.ch
- From: Dan Pop <danpop@mail.cern.ch>
- Newsgroups: comp.lang.c
- Subject: Re: Fastest way to computer log(base2) of x?
- Date: Tue, 6 Feb 1996 17:32:08 +0100
- Organization: CERN European Lab for Particle Physics
- Message-ID: <9602061633.AA15316@dxmint.cern.ch>
- References: <4e61iu$p6e@villa.fc.net> <4e72il$dvl@ns.RezoNet.NET> <4f647p$lc5@druid.borland.com>
- X-NNTP-Posting-Host: hpl3sn03.cern.ch
- X-Newsreader: NN version 6.5.0 #7 (NOV)
- X-Mail2News-Path: dxmint.cern.ch!hpl3sn03.cern.ch
-
- pete@borland.com (Pete Becker) writes:
-
- >Still faster: use a table with INT_MAX entries and remove all of the
- >conditionals. Why do the responses here assume that sacrificing speed for
- >space savings is appropriate? The question asks for the fastest, not something
- >that's reasonably fast but doesn't use much space.
-
- Initializing a table with 2147483648 entries might take quite a lot of
- time. That is, assuming that the system is configured with enough virtual
- memory :-)
-
- Dan
- --
- Dan Pop
- CERN, CN Division
- Email: danpop@mail.cern.ch
- Mail: CERN - PPE, Bat. 31 R-004, CH-1211 Geneve 23, Switzerland
-